<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        *{
            margin: 0;
            padding: 0;
        }
        #box{
            width: 600px;
            height: 300px;
            margin: 30px auto;
            padding: 30px 50px;
            border: 2px solid #b0cc50;
        }
        h1{
            text-align: center;
        }
        input{
            width: 270px;
            height: 40px;
            margin-left: 180px;
            margin-top: 80px;
            font-size: 20px;
            padding-left: 10px;
        }
    </style>
</head>
<body>
    <div id="box">
        <h1 v-model="msg" @click="fn()"><img src="./imags/pic.png" alt="">{{msg}}</h1>
        <div>
            <input type="text" v-model="msg" v-show="istrue">
        </div>
    </div>
    <script src="js/vue.js"></script>
    <script>
        let vm =new Vue({
            el:"#box",
            data:{
                msg:"Edit Me",
                istrue:false
            },
            methods:{
                fn(){
                    this.istrue=!this.istrue
                }
            }
        })
    </script>
</body>
</html>